<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta http-equiv="X-UA-Compatible" content="sie-edge"/>
    <link rel="icon" href="/favicon.ico" th:href="@{/favicon.ico}" sizes="32x32">
    <link href="/css/main/bootstrap.min.css" th:href="@{/css/main/bootstrap.min.css}" rel="stylesheet">
    <link href="/css/font-awesome.css" th:href="@{/css/font-awesome.css}" rel="stylesheet">
    <link rel="stylesheet" href="/css/tmp-index-style.css" th:href="@{/css/tmp-index-style.css}">
    <title>EasyShare-登录注册页</title>
    <link rel="stylesheet" type="text/css" href="/css/tmp-index-test.css" th:href="@{/css/tmp-index-test.css}">
    <link rel="stylesheet" href="/css/tmp-index-tip.css" th:href="@{/css/tmp-index-tip.css}">
    <style type="text/css">
        h1 {
            font-weight: bold;
            margin: 0;
            color: beige;
        }
    </style>
    <script src="/js/tmp-index-tip.js" th:src="@{/js/tmp-index-tip.js}"></script>
    <script src="/js/jquery-3.1.1.min.js" th:src="@{/js/jquery-3.1.1.min.js}"></script>
    <script src="/js/tmp-index-code.js" th:src="@{/js/tmp-index-code.js}"></script>

</head>

<body>
<input type="hidden" id="tip" th:value="${session.tip}">
<input type="hidden" id="findCookie" th:value="${findCookie}">
<div class="container" id="container">
    <div class="form-container sign-up-container">
        <form action="/user/register" method="post" id="register-form" onsubmit="return registerCheck()">
            <h1>第三方注册</h1>
            <div class="social-container"><a href="#" class="social" id="wechat-register">
                <i class="wechat-icon"></i>
            </a><a href="https://ssl.zc.qq.com/v3/index-chs.html" target="_blank" class="social">
                <i class="qq-icon"></i>
            </a></div>
            <span>或本站快速注册</span>
            <input name="username" type="text" maxlength="10" placeholder="昵称">
            <input name="useremail" type="text" maxlength="50" placeholder="邮箱">
            <input name="userpassword" type="password" maxlength="11" placeholder="密码">
            <button>注册</button>
        </form>
    </div>
    <div class="form-container sign-in-container">
        <form action="/user/login" method="post" class="login-form" onsubmit="return loginCheck()">
            <h1>第三方登录</h1>
            <div class="social-container"><a href="#" class="social">
                <i class="wechat-icon"></i>
            </a><a href="/qq/qqLogin" class="social">
                <i class="qq-icon"></i>
            </a></div>
            <span>或站内登录</span>
            <input name="username" type="text" maxlength="50" placeholder="邮箱、用户名、手机号"
                   th:value="${#request.getAttribute('userInfo')}">
            <input name="userpassword" type="password" maxlength="11" placeholder="密码"
                   th:value="${#request.getAttribute('userPass')}">
            <input name="logintype" type="hidden" placeholder="登录方式">
            <button>登录</button>
        </form>
        <form action="/user/login" method="post" class="login-form" onsubmit="return loginCheck()"
              style="display: none">
            <h1>第三方登录</h1>
            <div class="social-container"><a href="#" class="social">
                <i class="wechat-icon"></i>
            </a><a href="/qq/qqLogin" class="social">
                <i class="qq-icon"></i>
            </a></div>
            <span>或站内登录</span>
            <input name="username" type="text" maxlength="50" placeholder="邮箱、用户名、手机号"
                   th:each="cookie:${#httpServletRequest.getCookies()}" th:if="${cookie.getName() eq 'userInfo'}"
                   th:value="${cookie.getValue()}">
            <input name="userpassword" type="password" maxlength="11" placeholder="密码"
                   th:each="cookie:${#httpServletRequest.getCookies()}" th:if="${cookie.getName() eq 'userPass'}"
                   th:value="${cookie.getValue()}">
            <input name="logintype" type="hidden" placeholder="登录方式">
            <button>登录</button>
        </form>
    </div>
    <div class="overlay-container">
        <div class="overlay">
            <div class="overlay-panel overlay-left">
                <h1>欢迎回来</h1>
                <p>与我们保持联系请登录您的个人信息</p>
                <button class="ghost" id="signIn">登录</button>
            </div>
            <div class="overlay-panel overlay-right">
                <h1>欢迎光临</h1>
                <p>输入您的个人资料，并与我们一起开始旅程</p>
                <button class="ghost" id="signUp">注册</button>
            </div>
        </div>
    </div>
</div>

<script src="/js/tmp-index-script.js" th:src="@{/js/tmp-index-script.js}"></script>

</body>
</html>
